home *** CD-ROM | disk | FTP | other *** search
/ The Fatted Calf / The Fatted Calf.iso / Applications / Communication / NewsBase / Source / INntpIO.h < prev    next >
Text File  |  1993-01-12  |  3KB  |  90 lines

  1. /*$Copyright:
  2.  * Copyright (C) 1992.5.22. Recruit Co.,Ltd. 
  3.  * Institute for Supercomputing Research
  4.  * All rights reserved.
  5.  * NewsBase  by ISR, Kazuto MIYAI, Gary ARAKAKI, Katsunori SUZUKI, Kok-meng Lue
  6.  *
  7.  * You may freely copy, distribute and reuse the code in this program under 
  8.  * following conditions.
  9.  * - to include this notice in the source code, if it is to be distributed 
  10.  *   with source code.
  11.  * - to add the file named "COPYING" within the code, which shall include 
  12.  *   GNU GENERAL PUBLIC LICENSE(*).
  13.  * - to display an acknowledgement in binary code as follows: "This product
  14.  *   includes software developed by Recruit Co.,Ltd., ISR."
  15.  * - to display a notice which shall state that the users may freely copy,
  16.  *   distribute and reuse the code in this program under GNU GENERAL PUBLIC
  17.  *   LICENSE(*)
  18.  * - to indicate the way to access the copy of GNU GENERAL PUBLIC LICENSE(*)
  19.  *
  20.  *   (*)GNU GENERAL PUBLIC LICENSE is stored in the file named COPYING
  21.  * 
  22.  * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED
  23.  * WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
  24.  * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  25. $*/
  26.  
  27. #import "INewsGroupTreeControl.h"
  28. #import "ITreeNodeD.h"
  29. #import "IUifNode.h"
  30.  
  31. typedef      enum {Flat, Tree, BySubject, ByKeyword} BrowserMode;
  32.  
  33. #define    LISTCOL0TITLE        "- sort by Article number -"
  34. #define    BROWSERCOL0TITLE    "- sort by References -"
  35. #define    SUBJECTCOL0TITLE    "- sort by Subject -"
  36. #define    KEYWORDCOL0TITLE    "- sort by Keyword -"
  37.  
  38. #define        UNREADMARK    "unreadMark"
  39.  
  40. @interface INntpIO:INewsGroupTreeControl
  41. {
  42.     id         iArticleReferenceTreeRoot;
  43.     id         iArticleHashTable;
  44.     id        iArticleDB;
  45.     BrowserMode        iNewsGroupMode;
  46.     BrowserMode        iArticleMode;
  47.     ReadFlag    irFlag;
  48.     int        iBoundaryForTwo;        // mark for # of Lines
  49.     int        iBoundaryForThree;
  50. }
  51.  
  52. - initServer:(char *)nntpHost allNews:(BOOL)allNewsFlag
  53.             newsGroupMode:(BrowserMode)g_mode
  54.             articleMode:(BrowserMode)a_mode;
  55.  
  56. /* method for IO module */
  57. - subDirectoryOf:dataGroupDirNode;
  58. - itemHeadersOf:dataGroupNode;
  59. - itemOf:itemNode;
  60. - (BOOL)toggleActive:node;
  61.  
  62. /* change data tree structure */
  63. - _subDirectoryOf:node;
  64. - _flatDirectoryOf:node;
  65. - _itemHeadersOf:node;
  66. - _itemTreeHeadersOf:node;
  67. - _itemSubTreeHeadersOf:node;
  68. - (BrowserMode)toggleNewsGroupMode:sender;
  69. - (BrowserMode)toggleArticleMode:sender;
  70. - setArticleMode:(BrowserMode)articleMode;
  71. - setReadFlag:(ReadFlag)rflag;
  72.  
  73. - getArticleMarkFor:(int)linenum;
  74.  
  75. - _makeArticleTree;
  76. - (void)_addArticleToTree;
  77. //- (void)makeRefKey:articleItem :(char **)referencesListPtr :(int *)length;
  78. - (char *)findOriginalArticle:articleItem;
  79.  
  80. /* return browsermode */
  81. - (BrowserMode)newsGroupMode;
  82. - (BrowserMode)articleMode;
  83.  
  84. /* methods for BySubject mode */
  85. - (IOrderedListD *)_subjectHeadersOf:(IUifNode *)subjectNode;
  86. - (IOrderedListD *)_keywordHeadersOf:(IUifNode *)newsgroupNode;
  87. - _itemHeadersOfSubject:(IUifNode *)subjectNode;
  88.  
  89. @end
  90.